import React from 'react';
import PropTypes from 'prop-types';
import { Pane } from '@folio/stripes/components';

export default class Demo extends React.Component {
  static propTypes = {
    label: PropTypes.object.isRequired,
  };

  render() {
    // iframe settings设置单独访问时标志
    const win = window.location.href;
    const isIframeTag = win?.includes('settings') && win?.split('=')[1] === 'iframesetTag';
    return (
      <>
        {
        isIframeTag ?
          <div data-test-application-settings-general-message>
            参数设置
          </div> :
          <Pane defaultWidth="fill" fluidContentWidth paneTitle={this.props.label}>
            <div data-test-application-settings-general-message>
              参数设置
            </div>
          </Pane>
        }
      </>
    );
  }
}
